<?php
defined('JOC') or die;

class db_cache_query extends db_table
{
  protected $_table_name = 'cache_query' ;
  
	function __construct($params = Array())
	{
		parent::__construct($params) ;
	}
	public function delete()
	{
		global $user ,$db ;

		$result = false ; 
		if($user->isAdmin())
		{
			$sql = " TRUNCATE TABLE {prefix}{$this->_table_name} ; " ;
			$result = $db->simple_query($sql , false , -1 , false , true ) ;
		}
		return $result ;
	}
}